home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
BBS Toolkit
/
BBS Toolkit.iso
/
pc_board
/
upadr.zip
/
UPADR.PPS
< prev
Wrap
Text File
|
1993-05-07
|
4KB
|
146 lines
; User Address Update PPS File - Original By Ralph LoBianco
;
; Modified by Brian Hillis - Ability OnLine - Toronto Canada.
;
; To allow for Provice as well as State, and to allow for Canadian
; Postal Codes (as well as a few other tid-bits) and the ability to
; Display language and/or security screens.
;
; This PPL will let users update their address information ONLY,
; rather than using the W command to update everything.
;
; Modified again by Michele Stewart - SunShine PCBoard - Pembroke Pines, FL
; ...with some help from hubby, Peter, to check for blank address info before
; allowing update and to display a file called UPADR. Use as login script ONLY.
;
;Define variable's
STRING ANYTEXT
STRING COMMAND1
STRING COMMAND2
STRING COMMAND3
ANYTEXT=" 1234567890qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM"
;Get user info from the USER record
GETUSER
; /* If the Address PSA is enabled then also check to see if the Address 1
; and City fields are blank. If so, then this user has not yet given
; address information. */
IF (psa(3) & (strip(u_addr(0)," ") = "") & (strip(u_addr(2)," ") = "")) then
GOTO MAIN
ELSE
GOTO END
ENDIF
:MAIN
COMMAND1=""
COMMAND2=""
COMMAND3=""
CLS
dispfile ppepath()+"upadr", GRAPH+SEC+LANG
println "@X0E 1 @X0F- @X0BStreet & Number: @X0F",U_ADDR(0)
println "@X0E 2 @X0F- @X0B Suite or Unit: @X0F",U_ADDR(1)
println "@X0E 3 @X0F- @X0B City: @X0F",U_ADDR(2)
println "@X0E 4 @X0F- @X0B Province/State: @X0F",U_ADDR(3)
println "@X0E 5 @X0F- @X0BPostal/Zip Code: @X0F",U_ADDR(4)
println "@X0E 6 @X0F- @X0B Country: @X0F",U_ADDR(5)
println
inputstr "@X0E Select @X0F1 - 6@X0E, (@X0FQ@X0E)uit and save@X0F",COMMAND3,@X0E,1,"123456SQ ",10
println
if (COMMAND3="") goto MAIN
if (COMMAND3="1") goto ADDR0
if (COMMAND3="2") goto ADDR1
if (COMMAND3="3") goto ADDR2
if (COMMAND3="4") goto ADDR3
if (COMMAND3="5") goto ADDR4
if (COMMAND3="6") goto ADDR5
if (COMMAND3="Q") goto SAVEIT
:ADDR0
println
inputstr "@X0A Street & Number",COMMAND1,@X0E,45,ANYTEXT,10
if (COMMAND1="" | LEFT(COMMAND1,1)=" ") goto MAIN
U_ADDR(0)=COMMAND1
goto MAIN
:ADDR1
println
inputstr "@X0A Suite or Unit",COMMAND1,@X0E,30,ANYTEXT,10
if (COMMAND1="" | LEFT(COMMAND1,1)=" ") goto MAIN
U_ADDR(1)=COMMAND1
goto MAIN
:ADDR2
println
inputstr "@X0A City",COMMAND1,@X0E,30,ANYTEXT,10
if (COMMAND1="" | LEFT(COMMAND1,1)=" ") goto MAIN
U_ADDR(2)=COMMAND1
goto MAIN
:ADDR3
println
inputstr "@X0A Province/State",COMMAND1,@X0E,10,ANYTEXT,10
if (COMMAND1="" | LEFT(COMMAND1,1)=" ") goto MAIN
U_ADDR(3)=COMMAND1
goto MAIN
:ADDR4
println
inputstr "@X0A Postal/Zip Code",COMMAND1,@X0E,10,ANYTEXT,10
if (COMMAND1="" | LEFT(COMMAND1,1)=" ") goto MAIN
U_ADDR(4)=COMMAND1
goto MAIN
:ADDR5
println
inputstr "@X0A Country",COMMAND1,@X0E,15,ANYTEXT,10
if (COMMAND1="" | LEFT(COMMAND1,1)=" ") goto MAIN
U_ADDR(5)=COMMAND1
goto MAIN
:SAVEIT
if (U_ADDR(0)="" | LEFT(U_ADDR(0),1)=" ") then
goto NOINFO
elseif (U_ADDR(2)="" | LEFT(U_ADDR(2),1)=" ") then
goto NOINFO
elseif (U_ADDR(3)="" | LEFT(U_ADDR(3),1)=" ") then
goto NOINFO
elseif (U_ADDR(4)="" | LEFT(U_ADDR(4),1)=" ") then
goto NOINFO
endif
goto DONE
:NOINFO
println
println "@X0A You have NOT entered all the information required to complete"
println "@X0A your USER record. If you don't do it now, you'll be asked again"
println "@X0A each time you log on until the informaton is completed."
println
inputyn "@X0E Do you still want to Quit anyway (y/N)@X07",COMMAND2,@X0F
If (COMMAND2="Y") goto DONE
if (COMMAND2="N") goto MAIN
if (COMMAND2="") goto MAIN
:DONE
println
println "@X0A Thanks for taking the time to update your USER record @FIRST@."
println
println "@X0A In the future if you need to update this information, simply"
println "@X0A type @X0FW@X0A at the Main Command prompt.@X07"
println
PUTUSER
END
:END
END